package com.bw.workonedemo02.adapter

import android.widget.ImageView
import com.bumptech.glide.Glide
import com.bw.lib_base.entity.IVideoEntityItem
import com.bw.workonedemo02.R
import com.chad.library.adapter.base.BaseQuickAdapter
import com.chad.library.adapter.base.viewholder.BaseViewHolder


class IVideoAdapter:BaseQuickAdapter<IVideoEntityItem, BaseViewHolder>(R.layout.ivideo_item_adapter) {
    override fun convert(helper: BaseViewHolder, item: IVideoEntityItem) {
        helper.setText(R.id.tv_title,item.title)
        helper.setText(R.id.tv_desc,item.name)
        val ic_icon = helper.getView<ImageView>(R.id.ic_icon)
        Glide.with(context)
            .load(item.videomainimag)
            .into(ic_icon)
    }
}